<?php
set_include_path ( get_include_path () . PATH_SEPARATOR . '../' );
include_once 'Include.php';

$id = req ('id');
$userTable = new UserTable();

if($id != ""){
	$d = $userTable->find($id)->toArray();
	

	// send email
	$href = WWW."web/sign_activate.php?id=".$id."&validate=".$d[0]["validate"];
	$to      = $d[0]["email"];
	$subject = 'aba4hire.com Membership Activation';			
	$headers = 'From: danny@simplebyte.net' . "\r\n" .
		'Reply-To: danny@simplebyte.net' . "\r\n" .
		'X-Mailer: PHP/' . phpversion();
	$message = "<p>Congratulations, you got this email.</p>" . 
			"<p>Activate your account by clicking on the activation link below:</p>".
			"<p><a href='" . $href . "'>Activation link here</a></p>".
			"<p>Thanks again for signing up.</p>" .
			"<p>aba4hire.com team</p>".
			"<hr />".
			"<p>If this entry was sent to you without your consent or you have received this email in error, please ignore this email.</p>" . 
			"<p>We love to hear from you. Send us comments / opinions to support@aba4hire.com</p>";
	
	$send = @mail($to, $subject, $message, $headers);	
}
?>
<h3>You validate link is send, check you email please!</h3>